/*
 * @name:投票详情表(vote)
 * @content:
 * @Author: joyce
 * @Date: 2020-05-28 21:36:54
 */

var mongoose = require("mongoose");
var voteDetailSchema = new mongoose.Schema({
  voteId: { type: mongoose.SchemaTypes.ObjectId, ref: "vote" }, //投票id
  optionDetail: { type: Array }, //投票选项
  creatTime: { type: Date,default:new Date() },
  votepeople: { type: mongoose.SchemaTypes.ObjectId, ref: "user_login" } //此投票的投票人员的_id（length即被投票的次数）
});

module.exports = mongoose.model("voteDetail", voteDetailSchema);
